package br.com.eSink.util;

import java.io.File;
import java.io.FileWriter;
import java.io.IOException;
import java.io.PrintWriter;


import android.os.Environment;

public class Logging {

    public static void write(String text, boolean x) {
        File arq = new File(Environment.getExternalStorageDirectory(),"logging.txt");
        boolean statusArq;
        try {            
            FileWriter fileWriter = new FileWriter(arq, x);
            PrintWriter printWriter = new PrintWriter(fileWriter);
            printWriter.println(text);
            printWriter.flush();
            printWriter.close();

        } catch (IOException ex) {
        	System.out.println(ex.getMessage());
        }

    }
    
}
